package academia.persistencia;

import java.sql.Connection;
import java.sql.DriverManager;
import javax.swing.JOptionPane;

public class DBAcademia {

    Connection conn = null;

    public static Connection ConnectDB() {
        try {
            Class.forName("org.sqlite.JDBC");
            Connection conn = DriverManager.getConnection("JDBC:sqlite:C:\\Users\\Guilherme.Guilherme-PC\\SkyDrive\\Públicos\\bd projeto academia\\DBAcademia.sqlite");
            return conn;

        } catch (Exception e) {
            JOptionPane.showMessageDialog(null, e);
            return null;
        }
    }
}
